var version = '1.3';
seajs.config({
    alias:{
        'style':'../../../css/default.css',
        'jquery-ui-css':'../../../css/ui-lightness/jquery-ui-1.7.2.custom.css',
        'jquery-multiselect-css':'../../../css/ui-lightness/jquery.multiselect.css',
        'jqgrid-ui-css':'../../jquery/jqgrid/js/src/css/ui.jqgrid.css',
        'jqgrid-ui-css':'../../jquery/jqGrid-5.1.0/css/ui.jqgrid.css',
        'jqgrid-ui-bootstrap-css':'../../jquery/jqGrid-5.1.0/css/ui.jqgrid-bootstrap.css',
        'jqgrid-ui-bootstrap-ui-css':'../../jquery/jqGrid-5.1.0/css/ui.jqgrid-bootstrap-ui.css',
        'jquery': '../../jquery/jquery-1.7.2.min.js',
        'utils': '../../jquery/utils.js',
        //'jqgrid':'../../jquery/jqgrid/js/jquery.jqGrid.js',
        'jqgrid':'../../jquery/jqGrid-5.1.0/js/jquery.jqGrid.js',
        'jqcookie':'../../jquery/jquery.cookie.js',
        'angular':'../../angular/angular.min.js',
        'artDialog-skin': '../../../css/artDialog-skin/skins/blue.css',
        'artDialog': '../../jquery/artDialog/artDialog.min.js',
        'artDialog-plugins': '../../jquery/artDialog/artDialog.plugins.min.js',
        'ztreestyle': '../../../css/zTreeStyle/zTreeStyle.css',
        'ztree-core': '../../jquery/ztree/jquery.ztree.core-3.5.js',
        'ztree-excheck': '../../jquery/ztree/jquery.ztree.excheck-3.5.js',
        'ztree-exhide': '../../jquery/ztree/jquery.ztree.exhide-3.5.js',
        'highcharts': '../../highcharts1/highcharts.js',
        'highcharts-more': '../../highcharts1/highcharts-more.js',
        'exporting': '../../highcharts1/exporting.js',
        //'echarts': '../../echarts-2.2.7/build/source/echarts-all.js',
        //'echarts':'http://echarts.baidu.com/build/dist/echarts-all.js',
        'echarts': '../../echarts-2.2.7/echarts-all.js',
        'jquery-ui-timepicker-css': '../../../css/ui-lightness/jquery-ui-timepicker-addon.css',
        'jquery-ui-timepicker': '../../jquery/ui/jquery-ui-timepicker-addon.js',
        'jquery-multiselect': '../../jquery/ui/jquery.multiselect.js',
        'jquery-ui': '../../jquery/ui/jquery-ui-1.8.21.custom.min.js',
        'jquery-ui-timepicker-CN': '../../jquery/ui/localization/jquery-ui-timepicker-zh-CN.js',
        'mpos-directive':'../directive/mpos-directive.js',
        'mpos-controller':'../controller/mpos-controller.js',
        'mpos-service':'../service/mpos-service.js',
        'mpos-filter':'../filter/mpos-filter.js',
        'baiduMapJs-SearchInfo':'../../gis/SearchInfoWindow_min',//add
        'baiduMapApi':'../../gis/js/apiv1.3.min',//add
        'baiduMapCss': '../../gis/bmap.css',//add
        'baiduHeatMap': '../../gis/js/Heatmap_min.js',
        'jslider-css':'../../../css/jslider/jquery.slider.min.css',
        'jslider':'../../jquery/jslider/jquery.slider.min.js',
        'baiduDrawingManager': '../../gis/js/DrawingManager_min.js',
        'baiduDrawingManagerCss': '../../../css/gis/DrawingManager_min.css',
        'WdatePicker': '../../My97DatePicker/WdatePicker.js',
        'laydate':'../../../laydate/laydate.js'
        
//        'WdatePickerCss': '../../My97DatePicker/WdatePicker.css'
    },
    debug : 1,
    preload:[window.$ || window.jQuery ? '' :'jquery'],
    map: [
        ['.css', '.css?v=' + version],
        ['.js', '.js?v=' + version]
    ]
});

define(function (require, exports, module) {
    var $ = require('jquery');
    require('jquery-ui')($);
    require('angular');
    require('jqcookie')($);
    require('mpos-controller')($);
    require('mpos-directive')($);
    require('mpos-service')($);
    require('mpos-filter')($);
    require('WdatePicker');

    var mpos = angular.module('mpos-ps', ['mpos-controller', 'mpos-directive', 'mpos-service', 'page-ctrl','school-ctrl','school2-ctrl','dataBusiness-ctrl',
        'netPercept-ctrl','home-ctrl','dataBusiness-ctrl','hotPointMarket-ctrl','terminalAnalysis-ctrl','customquery-ctrl','systemManagement-ctrl',
        'test2-ctrl','checkIndicator-ctrl','_4gCellReside-ctrl','checkCellIndicator-ctrl','resourceDispatch-ctrl','sparkStreamPara-ctrl']);

    mpos.config(['$routeProvider',function ($routeProvider) {
        $routeProvider
            .when('/Home', {
                templateUrl: 'modules/Homepage.html'
            })
            .when('/HotPointNet', {
                templateUrl: 'modules/HotPointNetwork.html'
            })
            .when('/HotPointEnt', {
                templateUrl: 'modules/HotPointEntrance.html'
            })
            .when('/HotPointBus', {
                templateUrl: 'modules/HotPointBusiness.html'
            })
            .when('/Lv3Bus', {
                templateUrl: 'modules/Lv3Business.html'
            })
            .when('/TerminalHot', {
                templateUrl: 'modules/TerminalHotPoint.html'
            })
            .when('/TerminalBus', {
                templateUrl: 'modules/TerminalBusiness.html'
            })
            .when('/34G', {
                templateUrl: 'modules/34GPerception.html'
            })
            .when('/Custom', {
                templateUrl: 'modules/CustomGroups.html'
            })
            .when('/Network', {
                templateUrl: 'modules/Networkquality.html'
            })
            .when('/Business', {
                templateUrl: 'modules/Businessquality.html'
            })
            .when('/Scenario', {
                templateUrl: 'modules/Scenarioanalysis.html'
            })
            .when('/Customque', {
                templateUrl: 'modules/Customquery.html'
            })
            .when('/Model', {
                templateUrl: 'modules/Modeltask.html'
            })
            .when('/Page1', {
                templateUrl: 'modules/Page1.html'
            })
            .when('/Page2', {
                templateUrl: 'modules/Page2.html'
            })
            .when('/School',{
                templateUrl: 'modules/School.html'
            })
            .when('/School2',{
                templateUrl: 'modules/School2.html'
            })
            .when('/User',{
                templateUrl: 'modules/Usermanagement.html'
            })
            .when('/Role',{
                templateUrl: 'modules/Rolemanagement.html'
            })
            .when('/Test2',{
                templateUrl: 'modules/Test2.html'
            })
            .when('/Check',{
                templateUrl: 'modules/CheckIndicator.html'
            })
            .when('/_4GCell',{
                templateUrl: 'modules/4GCellReside.html'
            })
            .when('/CheckCell',{
                templateUrl: 'modules/CheckCellIndicator.html'
            })
            .when('/SpkStrPara',{
                templateUrl: 'modules/SparkStreamingParamanagement.html'
            })
            .when('/Dispatch',{
                templateUrl: 'modules/ResourceDispatch.html'
            })
            .otherwise({
            redirectTo: '/Home'
        });
    }]);
});